1. Field of the Invention
The present invention relates to a video apparatus comprising histogram modification means for matching at least luminance signals (Y) for separate pixels to prescribed values, the histogram modification means comprising a (first) memory with a (first) look-up table (LUT) for correcting the video luminance signals (Y).
2. Description of the Related Art
Video-image information may be composed of three components: primary color signals Exe2x80x2G, Exe2x80x2B, Exe2x80x2R or signals derived therefrom, particularly, a luminance signal Exe2x80x2Y and color-difference signals Exe2x80x2B-Y and Exe2x80x2R-Y. The primary color signals Exe2x80x2G, Exe2x80x2B, Exe2x80x2R are the gamma-corrected signals corresponding to green, blue and red information, respectively. A gamma correction is a compensation for CRT non-linearity by introducing a compensating non-linearity in the system. The luminance signal Exe2x80x2Y and the color-difference signals Exe2x80x2B-Y and Exe2x80x2R-Y are derived from the primary color signals and are, as in PAL systems, indicated by Exe2x80x2Y, Exe2x80x2U and Exe2x80x2V, or, for the sake of simplicity, by Y, U and V.
U.S. Pat. No. 4,450,482 describes a video apparatus with histogram modification means. The histogram modification therein is only realized for luminance signals Y. The histogram modification means performs contrast enhancement, and implies a non-linear transfer function to be applied to video signals in order to get a more even distribution of black, gray and white levels. In this known histogram modification, first the distribution function of the brightness levels of a representative set of pixels, i.e., a histogram, is measured. As already noted, the histogram may show an uneven distribution of dark, medium or bright pixels. A correction function is calculated that, when applied to the video signals, yields a more evenly distributed histogram, but not necessarily a flat histogram. The correction may be called a 0-dimensional correction because each new pixel value is only a non-linear function of the old pixel at the same spatial and temporal position. The non-linear correction function can be quite complicated, so it will usually involve a memory with a look-up table (LUT). By means of the look-up table, a luminance signal Yi of a pixel will be corrected to a value Yo.
It is, inter alia, an object of the invention to provide an improved histogram modification.
In practice, it appeared to be desirable to apply histogram modification correction in each of the three video information channels for the luminance and color-difference signals. Therefore, according to one embodiment of the invention, the video apparatus as described in the opening paragraph is characterized in that the histogram modification means comprises a second memory with a second look-up table, the values within said second look-up table being derived from the values in the first look-up table and being applied to correct the color-difference signals (U and V).
As the sample rate of the luminance signals (Y) is usually twice the sample rate of the color-difference signals (U and V), a sample rate converter is provided to adapt the sample rate of the luminance signals (Y) to that of the color-difference signals (U and V), the output signals of said sample rate converter being supplied to the second memory.
The first look-up table contains corrected luminance values in accordance with a predetermined correction function. To obtain corrected color-difference signals, the second look-up table contains gain-values, derivable from said predetermined correction function, e.g., being formed by values of the first derivative of the correction function, while the apparatus further comprises a multiplier in which the color-difference signals (U and V) are corrected by multiplication with the respective gain-values.
As, in practice, color-difference signal zero-values are represented by a certain digital number and such signals with zero-value must not be corrected, each of the color-difference signals is decreased by an offset value before multiplication and increased by said offset value after multiplication.
In a preferred embodiment, error-propagation is applied This means that in order to obtain a distribution of a rounding-off error over a pixel""s neighbor, each of the channels for the luminance (Y) and color-difference signals (U and V) comprises a closed lsb (least significant bit) correction loop with a quantizer and a pixel memory, the input of the lsb correction loop being formed by the corrected luminance and corrected color-difference signals, respectively.
From the above-mentioned U.S. Pat. No. 4,450,482, histogram modification is known. Apart from this document, many histogram algorithms have been developed. Most of them are rather complicated because, for each brightness level in the histogram, a corrected value is calculated. According to the invention, a histogram modification unit is provided by means whereby, from a measured histogram, a correction function is calculated on the basis of only three levels, particularly black, gray and white brightness levels in the measured histogram with only three control operators, in particularly, offset, gain and gamma, according to the relation:
Vo=[(Vi+offset)*gain]Gamma.
All corrected values are obtained from this relation.
These and other aspects of the invention will be apparent from and elucidated with reference to the embodiments described hereinafter.